:root {
    --font-stack: 'Roboto', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

html, body {
  padding: 0;
  margin: 0;
}

body {
  background: #fafafa;
  font-family: var(--font-stack);
  color: #333;
}

h3 {
  font-size: 20px;
  line-height: 28px;
}

h6 {
  margin: 12px 0;
  font-size: 16px;
  font-weight: normal;
  color: hsl(0,0%,63%);
}

paper-material {
  border-radius: 2px;
  height: 100%;
  padding: 16px 0 16px 0;
  width: calc(98.66% - 16px);
  margin: 16px auto;
  background: white;
}

paper-listbox {
  overflow-y: auto;
}

paper-listbox a, iron-selector a {
  text-decoration: none;
  display: -ms-flexbox;
  display: -webkit-flex;
  display: flex;
  -ms-flex-direction: row;
  -webkit-flex-direction: row;
  flex-direction: row;
  -ms-flex-align: center;
  -webkit-align-items: center;
  align-items: center;
  font-family: 'Roboto', 'Noto', sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 24px;
  min-height: 48px;
  padding: 0 16px;
}

paper-listbox a:hover, iron-selector a:hover {
  background: hsl(0,0%, 98%);
}

paper-listbox a.iron-selected, iron-selector a.iron-selected {
  border-right: 5px solid #4bbda8;
}

#drawer paper-dropdown-menu {
  padding: 0 16px;
  width: calc(100% - 32px);
  background: hsl(0, 0%, 82%)
}

#domainContainer {
  display: block;
  overflow-y: auto;
  height: 100%;
}

#versions {
  --paper-listbox-background-color: #c5cae9;
}

#drawerToolbar {
  height: 64px;
  min-height: 64px;
  display: flex;
  align-items: center;
  padding: 0 16px;
}

#mainToolbar {
  background: #3f51b5;
  color: white;
}

#mainToolbar .title {
  font-size: 20px;
  line-height: 20px;
  white-space: normal;
  overflow: visible;
}

.home-page-content {
  min-height: 102px;
  word-wrap: break-word;
}

.home-page-content h4 {
  margin-bottom: 0;
}

.home-page-content .screenshot div {
  background-repeat: no-repeat;
  text-indent: -999em;
  background-size: cover;
  height: 260px;
  background-position-y: -122px;
}

.gh-badge {
  float: right;
  width: 110px;
  height: 110px;
  shape-margin: 5px;
  shape-outside: polygon(0px 0px, 110px 0px, 110px 110px);
}

.gh-badge img {
  position: absolute; top: 0; right: 0; border: 0;
}


.home-page-content h5 {
  margin-bottom: 0px;
}

.home-page-content pre {
  margin: 8px 0;
  background: #efefef;
  overflow: auto;
  border-radius: 1px;
  padding: 3px 8px;
  border: 1px solid #d2d2d2;
}

.home-page-content h5,
.home-page-content h5 ~ * {
  margin-left: 20px;
}

span.experimental {
  font-size: 70%;
  text-transform: uppercase;
  background-color: #E57373;
  padding: 2px;
  cursor: help;
  color: white;
  vertical-align: baseline;
  font-weight: normal;
  font-family: inherit;
}
span.deprecated {
  background-color: hsla(0,0%,90%,1);
}

.domain-experimental span.experimental {
  display: none;
}

.domain-experimental .heading-domain span.experimental {
  display: inline-block;
}

.domain-experimental .heading-domain {
  border: 1px solid #E57373;
}

a.reflink {
    display: block;
    font-size: 12px;
    text-decoration: none;
    margin-top: -4px;
}

.monospace {
  font-family: Consolas, Menlo, monospace;
}
h4 {
    margin: 1rem 0 0.5rem;
}

h5 {
    color: gray;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 1rem 0 0;
}

p {
    margin: 0.5rem 0 1rem;
}

.method-name, .event-name {
    display: flex;
}

span.domain-dot {
    color: #ababab;
}

.parameter-list {
  padding: 0.5rem 5px;
  margin: 0 10%;
}

.param {
  border-left: 3px solid transparent;
}
.param:hover {
  border-left: 3px solid hsl(0, 0%, 84%);
}

.param-pair {
  display: -ms-flexbox;
  display: -webkit-flex;
  display: flex;
  align-items: baseline;
  margin-bottom: 6px;
}

.param-type {
  font-weight: bold;
}

.optional {
  opacity: .9;
}

.optional:after {
  content: "optional";
  opacity: .6;
  font-size: 70%;
  display: block;
}

.param-name {
  flex: 1 0 0;
  -ms-flex: 1 0 0;
  -webkit-flex: 1 0 0;
  text-align: right;
  color: black;
  word-wrap: break-word;
}

.param-def {
  flex: 3 0 0;
  -ms-flex: 3 0 0;
  -webkit-flex: 3 0 0;
  margin-left: 20px;

  display: -ms-flexbox;
  display: -webkit-flex;
  display: flex;
  flex-direction: column;
  -ms-flex-direction: column;
  -webkit-flex-direction: column;
}

.param-def, .param-name {
  vertical-align: text-top;
}

.param-sub > .param-def {
  border-left: solid hsl(0, 0%, 85%) 1px;
  padding-left: 5px;
}

.param-description {
  font-size: 90%;
}
.param-description code {
    font-size: 120%;
}

.permalink {
  margin-left: 5px;
  vertical-align: top;
  text-decoration: none;
  opacity: 0;
}

.permalink:hover {
  text-decoration: underline;
}

h4 {
  margin: 18px 0;
}

h4:hover .permalink {
  opacity: 1;
}

/* Breakpoints */

/* Wide */
@media (max-width: 980px) {
  #mainContainer .content {
    padding: 48px 40px;
  }
  .parameter-list {
    margin: 0;
  }
}

/* Small */
@media (max-width: 600px) {

  h3 {
    margin-left: 7px;
  }

  paper-material {
    --menu-container-display: none;
    width: calc(97.33% - 32px);
    padding-left: 8px;
    padding-right: 8px;
  }

  .content {
    padding: 48px 10px;
  }

  #drawer .paper-toolbar {
    margin-left: 16px;
  }
}

/* extra narrow */
@media (max-width: 405px) {
  body {
    font-size: 13px
  }

  .content {
    padding: 18px 0px;
  }

  paper-material {
    padding-left: 8px;
    padding-right: 8px;
    margin: 0;
    width: calc(100% - 16px);
  }
}

/* Tablet+ */
@media (min-width: 601px) {

  paper-material {
    width: calc(98% - 46px);
    margin-bottom: 32px;
    padding-left: 22px;
    padding-right: 22px;
  }

  #drawer {
    border-right: 1px solid rgba(0, 0, 0, 0.14);
  }

  .content {
    padding: 48px 20px;
  }

  #mainToolbar .title {
    font-size: 26px;
    line-height: 26px;
  }
}

/* <app-drawer> by default shown */
@media (min-width: 641px) {
  #paperToggle {
    display: none;
  }
}

/* Search Control styles */
.search-active  .title {
  display: none;
}
.search-active #paperToggle {
  display: none;
}
.search-active  cr-search-control {
  width: 100%;
}


/* selected item highlighting */
:target, :target ~ * {
    margin-left: -10px;
    border-left: 2px solid #3f51b5;
    padding-left: 10px;
}